package com.mcp.mslocalmcp.model;

import com.fasterxml.jackson.annotation.JsonProperty;

public class McpResponse {
    @JsonProperty("jsonrpc")
    private String jsonrpc;
    
    @JsonProperty("id")
    private String id;
    
    @JsonProperty("result")
    private Object result;
    
    @JsonProperty("error")
    private McpError error;
    
    // 构造函数
    public McpResponse() {}
    
    public McpResponse(String jsonrpc, String id, Object result) {
        this.jsonrpc = jsonrpc;
        this.id = id;
        this.result = result;
    }
    
    public McpResponse(String jsonrpc, String id, McpError error) {
        this.jsonrpc = jsonrpc;
        this.id = id;
        this.error = error;
    }
    
    // Getter和Setter方法
    public String getJsonrpc() {
        return jsonrpc;
    }
    
    public void setJsonrpc(String jsonrpc) {
        this.jsonrpc = jsonrpc;
    }
    
    public String getId() {
        return id;
    }
    
    public void setId(String id) {
        this.id = id;
    }
    
    public Object getResult() {
        return result;
    }
    
    public void setResult(Object result) {
        this.result = result;
    }
    
    public McpError getError() {
        return error;
    }
    
    public void setError(McpError error) {
        this.error = error;
    }
} 